
$(function() {
	var _vv_option = {
		rules: {
			name: "required",
			fullname: "required"
		},
		errorPlacement: function(label, element) {
			label.insertAfter(element);
		},
		success: function(label) {
			label.html("&nbsp;").addClass("checked");
		}
	};	
	
	validator = $("#form_add").validate(_vv_option);

	$("select[name=category_t]").change(function() {
		var s = $("select[name=category_t]").val();
		if (s != null && s != '-')　{
			$("input[name=category]").val(s);
		}		
	});

	 $('textarea').css("width", 400);
});
